﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace TB_CS.Plug
{
    public partial class Change_Money : Form
    {
        private static string QR_Scene;
        public Change_Money(string QR_Scene_id)
        {
            QR_Scene = QR_Scene_id;
            InitializeComponent();
        }

        private void Change_Money_Load(object sender, EventArgs e)
        {
            this.Text = "修改红包：" + QR_Scene.ToString() + " 的金额";
            label2.Text = QR_Scene;
        }

        private void button1_Click(object sender, EventArgs e)
        {
            if (textBox1.Text == "")
            {
                MessageBox.Show("请输入新的红包金额");
                textBox1.Focus();
            }
            else
            {
                try
                {
                    Class.SysInfo.WSHB.CHANGE_HONGBAO_MONEY(QR_Scene, (Convert.ToInt32(textBox1.Text.Trim().ToString()) * 100));
                    MessageBox.Show("更新成功");
                    this.Close();
                }
                catch (Exception ex)
                {
                    MessageBox.Show(ex.Message.ToString());
                }
            }
        }
    }
}
